package com.cyz.vo;

import lombok.Data;

import java.util.Objects;

@Data
public class CourseDto {

    private int id;

    private String courseName;

    private String teacherName;

    private String studentName;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        CourseDto courseDto = (CourseDto) o;
        return courseName == courseDto.courseName && Objects.equals(teacherName, courseDto.teacherName);
    }

    @Override
    public int hashCode() {
        return Objects.hash(courseName, teacherName);
    }
}
